<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" 
%><%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" 
%><%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" 
%><%@ page contentType="text/html;charset=ISO-8859-1"
%><html:html locale="true">
    <head>
        <title><bean:message key="asignaturaDepartamentoCrear.title"/></title>
        <html:base/>
         <script type="text/javascript">
         function selecciona(opcion){
         
                var valor = opcion.options[opcion.selectedIndex].value;
                
                 if (valor=="1"){
                             document.getElementById("url_C").className = "visible";
                             document.getElementById("archivo_C").className = "oculto";
                     }
                 else{
                        if(valor == "2"){
                            document.getElementById("archivo_C").className = "visible";
                            document.getElementById("url_C").className = "oculto";
                        }
                        else{
                             document.getElementById("archivo").className = "oculto";
                            document.getElementById("url").className = "oculto";
                            
                           }
                   }
    
          }

        </script>
        <link rel="stylesheet" type="text/css" href="../css/style.css"></link>
<style type="text/css">
.oculto{display:none;}
.visible{display:inline;}
div#box30420 {width: 400px; margin: 40px auto; }
form#30420 {float: left; margin: 0; padding: 0; display: inline; width: 400px; }
form#30420 p {float: left; margin: 0; padding: 0; display: inline; }
form#30420 label {float: left; margin: 0; padding: 0; display: inline; overflow: hidden; }
form#30420 input {float: left; margin: 0; padding: 0; display: inline; }
  form#30420 p#30427_C {clear: both; width: 400px; }
  form#30420 p#30427_C label {clear: both; width: 400px; }
  form#30420 p#30427_C input {clear: both; width: 396px; }
  form#30420 p#30426_C {clear: both; width: 400px; }
  form#30420 p#30426_C label {clear: both; width: 400px; }
  form#30420 p#30426_C input {clear: both; width: 396px; }
  form#30420 p#30429_C {clear: both; width: 400px; }
  form#30420 p#30429_C label {clear: both; width: 400px; }
  form#30420 p#30429_C input {clear: both; width: 396px; }
  form#30420 p#30424_C {clear: both; width: 400px; }
  form#30420 p#30424_C label {clear: both; width: 400px; }
  form#30420 p#30424_C input {clear: both; width: 396px; }
  form#30420 p#30428_C {clear: both; width: 400px; }
  form#30420 p#30428_C label {clear: both; width: 400px; }
  form#30420 p#30428_C input {clear: both; width: 396px; }
  form#30420 p#30423_C {clear: both; width: 400px; }
  form#30420 p#30423_C label {clear: both; width: 400px; }
  form#30420 p#30423_C input {clear: both; width: 396px; }
  form#30420 p#30421_C {clear: both; width: 400px; }
  form#30420 p#30421_C label {clear: both; width: 400px; }
  form#30420 p#30421_C input {clear: both; width: 396px; }
  form#30420 p#30422_C {clear: both; width: 400px; }
  form#30420 p#30422_C label {clear: both; width: 400px; }
  form#30420 p#30422_C input {clear: both; width: 396px; }
  form#30420 p#30425_C {clear: both; width: 400px; }
  form#30420 p#30425_C label {clear: both; width: 400px; }
  form#30420 p#30425_C input {clear: both; width: 396px; }
  form#30420 p#url_C label {clear: both; width: 400px; }
  form#30420 p#url_C input {clear: both; width: 396px; }
  form#30420 p#archivo_C label {clear: both; width: 400px; }
  form#30420 p#archivo_C input {clear: both; width: 396px; }
  

</style>
    </head>
    <body>
        <div id="header">
            <div id="title"><bean:message key="asignaturaDepartamentoCrear.title"/></div>
            <div id="menu">
                <ul id="nav">
                    <li><html:link action="/DepartamentoI.do" paramId="idDepartamento" paramName="idDepartamento"><bean:message key="asignaturaDepartamentoCrear.label1"/></html:link></li>

                </ul>
            </div>
        </div>
        <div id="body_wrapper">
            <div id="body">
                <div id="split">
                    <div class="top"></div>
                    <div id="left">
                        <div class="content">
                            ${empty msg ? "" : msg}
                <div class="box30420">
                    <table align="center" border="0">
                        <html:form styleId="F30420" action="/AsignaturaCrear.do" method="post" enctype="multipart/form-data">
                            <html:hidden property="idAsignatura"/>
                            <tr id="30426_C"><td align="left"><label for="30426"><bean:message key="FAsignatura.label1"/></label></td><td align="center"><html:text styleId="30426" property="codigo" size="30"/></td></tr>
                            <tr id="30429_C"><td align="left"><label for="30429"><bean:message key="FAsignatura.label2"/></label></td><td align="center"><html:text styleId="30429" property="nombre" size="30"/></td></tr>
                            <html:hidden styleId="30424" property="departamento"/>
                            <tr id="30423_C"><td align="left"><label for="30423"><bean:message key="FAsignatura.label5"/></label></td><td align="center"><html:text styleId="30423" property="horast" size="30"/></td></tr>
                            <tr id="30421_C"><td align="left"><label for="30421"><bean:message key="FAsignatura.label6"/></label></td><td align="center"><html:text styleId="30421" property="horasp" size="30"/></td></tr>
                            <tr id="30422_C"><td align = "left"><label for="30422"><bean:message key="FAsignatura.label7"/></label></td><td align="center"><html:text styleId="30422" property="horasl" size="30"/></td></tr>
                            <tr id="30425_C"><td align ="left"><label for="30425"><bean:message key="FAsignatura.label8"/></label></td><td align="center"><select onchange="selecciona(this)"> <option value="0">Seleccione</option><option value="1">URL</option><option value="2">Archivo</option></select></td></tr>
                               <tr id="url_C" class="oculto" ><td align = "left"><label for="url"><bean:message key="FAsignatura.label9"/></label></td><td align="center"><html:text styleId="url" property="programa2" size="30"/></td></tr>
                               <tr id="archivo_C" class="oculto"><td align = "left"><label for="archivo"><bean:message key="FAsignatura.label9"/></label></td><td align="right"><html:file styleId="archivo" property="programa1" size="20"/></td></tr>
                               <tr><td>&nbsp;</td><td>&nbsp;</td></tr>
                            <tr><td></td><td align="center"><html:submit styleClass="button"><bean:message key="asignaturaDepartamentoCrear.label0"/></html:submit></center><td></td></tr>
                        </html:form>
                    </table>
            </div>

                        </div>
                    </div>
                    <div id="right"><jsp:include page="/ppal/menu.jsp" flush="true"/></div>
                    <div class="clearer"></div>
                    <div class="bottom"></div>
                </div>
                <div class="clearer"></div>
            </div>
            <div class="clearer"></div>
        </div>
        <div id="end_body"></div>
        <h3 class="title"></h3>
        <div id="footer"> <bean:message key="bottom.label"/> </div>
        
    </body>
</html:html>